perm filename EEDIT4.2[EAL,HE]1 blob
sn#674831 filedate 1982-09-27 generic text, type C, neo UTF8
COMMENT ⊗ VALID 00003 PAGES
C REC PAGE DESCRIPTION
C00001 00001
C00002 00002 {$NOMAIN Editor: Part of editStmnt }
C00003 00003 procedure eEditOther (n: nodep l,indent,e0,elen: integer
C00006 ENDMK
C⊗;
{$NOMAIN Editor: Part of editStmnt }
%include eedit.hdr;
{ Externally defined routines from elsewhere: }
(* From EEXPED *)
function exprEditor(line,lstart,llength,estart: integer;
var elength: integer; off: integer): ascii; external;
(* From EPAR3B *)
procedure eClabelParse(n: nodep); external;
(* From EPAR3C *)
function eProcParse(n: nodep; indent,l: integer): ascii; external;
(* From EPAR3E *)
procedure eMClauseParse(n: nodep); external;
(* From EEDITS *)
procedure echarDo (echar: ascii; var again: boolean); external;
procedure eEditOther (n: nodep; l,indent,e0,elen: integer;
var echar: ascii; var again: boolean); external;
procedure eEditOther;
begin
with n↑ do
if ntype = procdefnode then
begin
(* *** check that procedure is not currently active ??? *** *)
echar := eProcParse(n,indent,l);
end
else if ntype = clistnode then
begin (* edit the label *)
e0 := indent + 1;
with lines[l]↑ do
begin (* go edit it *)
elen := length - e0 + 1;
echar := exprEditor(l-firstDline+1,start,length,e0,elen,0);
end;
eClabelParse(n);
end
else
begin (* a motion clause *)
if ntype = destnode then e0 := 3
else if ntype = viaptnode then e0 := 4
else if ntype = cwnode then e0 := 0
else if ntype = commentnode then e0 := 0 (* *** should be a little smarter here *** *)
else e0 := 5; (* a WITH clause *)
e0 := e0 + indent;
with lines[l]↑ do
begin (* go edit it *)
elen := length - e0 + 1;
if listing[start+length-1] = ';' then elen := elen - 1;
(* ** should also check for THEN at end if VIA ** *)
echar := exprEditor(l-firstDline+1,start,length,e0,elen,0);
end;
eMClauseParse(n);
end;
echarDo(echar,again);
end;